package io.modelcontextprotocol.util;

import java.util.*;

public class ListUtils {

    public static <T> List<T> of(T ... elements) {
        List<T> list = new ArrayList<T>();
        list.addAll(Arrays.asList(elements));
        return list;
    }


    public static <T> List<T> ofArr(T[] element) {
        List<T> list = new ArrayList<T>();
        list.addAll(Arrays.asList(element));
        return list;
    }

    public static <T> List<T> ofList(List<T> elements) {
        List<T> list = new ArrayList<T>();
        list.addAll(elements);
        return list;
    }

    public static <T> List<T> of() {
        return new ArrayList<>();
    }
}
